﻿using Newtonsoft.Json;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace Project.Core.Config.Entity {
    public class BaseEntity<L>
    {
        /// <summary>
        /// id
        /// </summary>
        [Key]
        [DatabaseGenerated(DatabaseGeneratedOption.Identity)]
        [Column("id")]
        public L Id { get; set; }

        public override string ToString() {
            return JsonConvert.SerializeObject(this);
        }
    }
}
